Image exposure using exclusion regions

ABSTRACT

Calculating a gain setting for a primary image sensor includes receiving a test-matrix of pixels from a test image sensor, and receiving a first-frame matrix of pixels from a primary image sensor. A gain setting is calculated for the primary image sensor using the first-frame matrix of pixels except those pixels imaging one or more exclusion regions identified from the test matrix of pixels.

BACKGROUND

Image sensors are used in a wide variety of devices. Electrical signals from image sensors may be amplified and processed to provide a visual representation of a scene. The magnitude of the amplification (gain setting) may affect the appearance of the image.

For example, if a scene to be imaged contains a bright region and a dark region, a gain setting may be calculated to provide a compromise between the appearance of the bright region and the dark region on the image. The dynamic range of the sensor (e.g., either the charge storage or the width of an analog to digital converter used to measure the charge) may be insufficient to capture the worst case dynamic range for a particular scene. As such, some regions of an image may not appear as desired.

SUMMARY

This Summary is provided to introduce a selection of concepts in a simplified form that are further described below in the Detailed Description. This Summary is not intended to identify key features or essential features of the claimed subject matter, nor is it intended to be used to limit the scope of the claimed subject matter. Furthermore, the claimed subject matter is not limited to implementations that solve any or all disadvantages noted in any part of this disclosure.

According to one aspect of this disclosure, calculating a gain setting for a primary image sensor includes receiving a test-matrix of pixels from a test image sensor, and receiving a first-frame matrix of pixels from a primary image sensor. A gain setting is calculated for the primary image sensor using the first-frame matrix of pixels except those pixels imaging one or more exclusion regions identified from the test matrix of pixels.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 shows an example method of calculating an exposure setting in accordance with an embodiment of the present disclosure.

FIG. 2 shows an example environment for calculating an exposure setting in accordance with an embodiment of the present disclosure.

FIG. 3 shows a first-frame image of a scene in accordance with an embodiment of the present disclosure.

FIG. 4 schematically shows a computing system for performing the method of FIG. 1.

DETAILED DESCRIPTION

The present description is related to calculating an exposure setting for a primary image sensor, including but not limited to a visible-light digital camera sensor. An exposure setting may include any number of settings, such as a gain setting, aperture setting, or shutter speed, for example. As one example, a gain setting may be calculated in accordance with the present disclosure based on a subset of pixels which do not image one or more exclusion regions that are identified using a test image sensor, such as a depth camera.

FIG. 1 shows an embodiment of a method 100 of calculating an exposure setting for a primary image sensor. The primary image sensor may be used to generate a digital representation of a scene. Various types of primary image sensors may be used without departing from the scope of this disclosure. As nonlimiting examples, a charge-coupled device (CCD) or complementary metal-oxide-semiconductor (CMOS) image sensor may be used. The primary image sensor may be incorporated in virtually any device where light information is to be captured, such as gaming consoles, mobile devices, personal computers, and digital single lens reflex (DSLR) cameras, for example. The exposure setting may be a gain setting indicating a level of amplification of an electric signal, such as a current, a charge, or a voltage, for example.

At 110, the method 100 includes receiving a test matrix of pixels from a test image sensor. In some embodiments, the test image sensor is used to observe and output infrared light information in the form of a test matrix of pixels. Each pixel in the test matrix may include infrared light information indicating an intensity of infrared light observed at that pixel. However, in some embodiments the test image sensor may be a visible light image sensor, and each pixel in the test matrix may include visible light information indicating an intensity of visible light observed at that pixel.

The test matrix may be received from the test image sensor via any suitable communication channel. Wired or wireless connections may be used.

At 120, the method 100 includes receiving a first-frame matrix of pixels from a primary image sensor. The primary image sensor may be any sensor suitable for observing and outputting light information, such as a CCD or CMOS image sensor. In some embodiments, the primary image sensor is used to observe and output visible light information in the form of a first-frame matrix of pixels. In some embodiments, each pixel in the first-frame matrix includes visible light information indicating an intensity of visible light observed at that pixel. For example, each pixel may include an intensity value for each of one or more different color channels, The first-frame matrix of pixels, as well as the individual pixels, may be represented using any suitable data structure without departing from the scope of this disclosure.

The first-frame matrix may be received from the primary image sensor via any suitable communication channel. Wired or wireless connections may be used.

At 130, the method 100 includes identifying one or more exclusion regions imaged by a subset of the test matrix of pixels. Exclusion regions may include any portion of a scene that is not to be used for the purposes of calculating an exposure setting. As a nonlimiting example, a user may want to image an object in a scene which is backlit by a light source. The bright background of the scene may be identified as an exclusion region, and the exposure setting may be calculated without considering the bright background. Any suitable method and/or criteria may be utilized to identify exclusion regions.

For example, identifying exclusion regions may include finding a depth of an object observed at each pixel in the test matrix. The depth of an object may be found by using the test image sensor in a depth camera, for example. The depth camera may determine, for each pixel in the test matrix, the three dimensional depth of a surface in the scene relative to the depth camera. Virtually any depth finding technology may be used without departing from the scope of this disclosure (e.g., structured light, time-of-flight, stereo vision, etc.). When a depth camera is used, the three dimensional depth information determined for each pixel may be used to generate a depth image. Depth images may take the form of virtually any suitable data structure, including but not limited to, a matrix of pixels, where each pixel indicates a depth of an object observed at that pixel.

The pixel(s) from the depth image may be mapped to the corresponding pixel(s) from the primary image sensor in contemporaneous and/or subsequent frames. In this way, the depth of an object imaged by the primary image sensor may be determined. The exclusion regions may include a subset of pixels that image an object that is not within a threshold tolerance of a reference depth. For example, all pixels from the primary image sensor that image objects that are closer than a near-limit and/or are farther than a far-limit, as determined by the test matrix of pixels, may be effectively ignored for purposes of determining an exposure setting. As explained below, such exclusion regions may be applied to exposure calculations for one or more frames.

As another example, identifying exclusion regions may include finding a surface temperature of an object observed at each pixel. The test matrix may be used to determine the surface temperature. The surface temperature may be found via any number of techniques, such as using a look up table to correlate an intensity of infrared light to a surface temperature of an object.

The temperature(s) determined using the test matrix may be mapped to the pixel(s) from the primary image sensor. In this way, the surface temperature of an object imaged by the primary image sensor may be determined. The exclusion regions may include a subset of pixels that image an object that is not within a threshold tolerance of a reference surface temperature. For example, all pixels from the primary image sensor that image objects that are hotter than a high-limit and/or are cooler than a cool-limit, as determined by the test matrix of pixels, may be effectively ignored for one or more frames when determining an exposure setting. The cool-limit could be utilized when focusing on human subjects, and the high-limit could be utilized to ignore a lamp, for example

As another example, identifying exclusion regions may include finding regions of high active and/or ambient light. As a nonlimiting example, high active and/or ambient light may be determined by projecting infrared light onto a scene and imaging the scene with a first matrix of pixels while the infrared light is being projected. The same scene can also be imaged with a second matrix of pixels when the infrared light is not being projected onto the scene. By comparing the images with and without the projected infrared light, active and/or ambient light can be identified. Any suitable comparison technique may be used, including but not limited to subtracting the first matrix from the second matrix.

By comparing these matrices, it may be determined which pixels in the first-frame matrix image regions of high ambient light. High ambient light regions may result from a lamp, the sun, or anything else adding light to one or more regions of a scene. The exclusion regions may include a particular pixel if the intensity of infrared light observed at that pixel while infrared light is being projected to that pixel is within a threshold tolerance of the intensity of infrared light observed at that pixel while infrared light is not being projected to that pixel. In other words, if the pixel images an area that is saturated with enough infrared light that the addition of projected infrared light does not cause a significant difference, that pixel can be included in an exclusion region.

While the above testing for ambient light was described with reference to projecting and imaging infrared light, it is to be understood that a similar technique may be used with visible light.

At 140, the method 100 may include calculating an exposure setting for the primary image sensor using the first-frame matrix of pixels except those pixels imaging one or more exclusion regions identified from the test matrix of pixels. For example, a histogram of the first-frame matrix of pixels except the pixels imaging the one or more exclusion regions may be constructed. The exposure setting may be calculated based on this histogram.

A gain setting or other exposure control may be adjusted so that a histogram of pixel intensities has a desired character. As an example, the exposure can be increased and/or decreased so that an average intensity, as represented by the histogram, is within a desired range. Because the histogram does not consider pixels from the exclusion regions, those pixels do not influence the adjustments. As a result, the adjustments are tuned to improve the exposure of the pixels that are not part of the exclusion regions. It should be appreciated that virtually any technique for calculating an exposure setting based on a histogram may be used without departing from the scope of this disclosure.

In this way, those pixels imaging exclusion regions may not be considered when calculating an exposure setting, and thus the exposure setting may provide a better image in regions of interest.

It is to be understood that the test matrix of pixels and the first-frame matrix of pixels may be sampled at different times relative to one another without departing from the scope of this disclosure. In some embodiments, the test matrix of pixels will be sampled prior to the first-frame matrix of pixels.

In some embodiments, the primary image sensor may provide sequential frames which collectively form a video representation of a scene. At 150, the method 100 may include applying the calculated exposure setting to the primary sensor for subsequent matrices of pixels. In other words, the exposure setting may be calculated at a fixed period, such as every frame, every other frame, after a fixed duration, every time the game console is powered on, and/or if a threshold change in lighting or scene composition is detected, for example.

The period may be dependent on whether or not the primary image sensor is substantially stationary. For example, for a fixed camera, if the user frequently eclipses a light source from the camera perspective, that region may always be excluded to avoid variability in the exposure/gain settings.

FIG. 2 shows an example environment 200 for calculating an exposure setting. In particular, FIG. 2 shows a gaming system 240, a primary image sensor 210, a test image sensor 220, a display device 230, an infrared light source 290 and a user 250. The environment 200 may further include an active light source 260, a couch 270, and a background person 280.

The display device 230 may be operatively connected to the gaming system 240 via a display output of the gaming system. For example, the gaming system may include an HDMI or other suitable display output. Likewise, the primary image sensor 210, test image sensor 220, and infrared light source 290 may be operatively connected to the gaming system 240 via one or more inputs. As a nonlimiting example, the gaming system 240 may include a universal serial bus to which a device including the image sensors may be connected. The image sensors and the gaming system 240 may be configured to wirelessly communicate with one another.

Gaming system 240 may be used to play a variety of different games, play one or more different media types, and/or control or manipulate non-game applications and/or operating systems.

In the illustrated embodiment, the test image sensor is used in a depth camera capable of generating depth maps, temperature maps, and otherwise observing and outputting infrared light information, as described above with reference to FIG. 1. The primary image sensor is used in a conventional RGB camera capable of observing visible light information to form a color image of a scene.

The image of the scene may be displayed on the display device 230, further processed, or sent to another device, for example. Exposure settings for the primary image sensor may be calculated using a previously sampled image.

A simplified representation of an example first-frame image 300 is shown in FIG. 3. In particular, FIG. 3 shows example exclusion regions 360, 370, and 380. The pixels in the example exclusion regions 360, 370, and 380 image the active light source 260, couch 270 and background person 280, respectively. The example exclusion regions may be identified according to aspects of the method 100 of FIG. 1.

For example, exclusion region 380 includes pixels that image an object (e.g. the background person 280) not within a threshold tolerance of a reference depth. Exclusion region 370 includes pixels that image an object (e.g. the couch 270) not within a threshold tolerance of a reference surface temperature.

Exclusion region 360 includes pixels where the intensity of infrared light observed at that pixel while infrared light is being projected to that pixel is within a threshold tolerance of the intensity of infrared light observed at that pixel while infrared light is not being projected to that pixel. In other words, exclusion region 360 includes those pixels imaging the active light source 260.

A histogram of the first-frame matrix of pixels except the pixels imaging the one or more exclusion regions may be constructed. In the illustrated embodiment, the histogram does not include those pixels imaging the active light source 260, the couch 270, or the background person 280. Using the histogram, the exposure setting may be calculated and applied for subsequent matrices of pixels. As described above, this process may be repeated periodically.

In some embodiments, the above described methods and processes may be tied to a computing system including one or more computers. In particular, the methods and processes described herein may be implemented as a computer application, computer service, computer API, computer library, and/or other computer program product.

FIG. 4 schematically shows a nonlimiting computing system 400 that may perform one or more of the above described methods and processes. Computing system 400 is shown in simplified form. It is to be understood that virtually any computer architecture may be used without departing from the scope of this disclosure. In different embodiments, computing system 400 may take the form of a mainframe computer, server computer, desktop computer, laptop computer, tablet computer, home entertainment computer, network computing device, mobile computing device, mobile communication device, gaming device, etc. Gaming system 240 of FIG. 2 is a nonlimiting example of computing system 400.

Computing system 400 includes a logic subsystem 402 and a data-holding subsystem 404. Computing system 400 may optionally include a display subsystem 406, communication subsystem 408, sensor subsystem 410, and/or other components not shown in FIG. 4. Computing system 400 may also optionally include user input devices such as keyboards, mice, game controllers, microphones, and/or touch screens, for example.

Logic subsystem 402 may include one or more physical devices configured to execute one or more instructions. For example, the logic subsystem may be configured to execute one or more instructions that are part of one or more applications, services, programs, routines, libraries, objects, components, data structures, or other logical constructs. Such instructions may be implemented to perform a task, implement a data type, transform the state of one or more devices, or otherwise arrive at a desired result.

The logic subsystem may include one or more processors that are configured to execute software instructions. Additionally or alternatively, the logic subsystem may include one or more hardware or firmware logic machines configured to execute hardware or firmware instructions. Processors of the logic subsystem may be single core or multicore, and the programs executed thereon may be configured for parallel or distributed processing. The logic subsystem may optionally include individual components that are distributed throughout two or more devices, which may be remotely located and/or configured for coordinated processing. One or more aspects of the logic subsystem may be virtualized and executed by remotely accessible networked computing devices configured in a cloud computing configuration.

Data-holding subsystem 404 may include one or more physical, non-transitory, devices configured to hold data and/or instructions executable by the logic subsystem to implement the herein described methods and processes. When such methods and processes are implemented, the state of data-holding subsystem 404 may be transformed (e.g., to hold different data).

Data-holding subsystem 404 may include removable media and/or built-in devices. Data-holding subsystem 404 may include optical memory devices (e.g., CD, DVD, H-D-DVD, Blu-Ray Disc, etc.), semiconductor memory devices (e.g., RAM, EPROM, EEPROM, etc.) and/or magnetic memory devices (e.g., hard disk drive, floppy disk drive, tape drive, MRAM, etc.), among others. Data-holding subsystem 404 may include devices with one or more of the following characteristics: volatile, nonvolatile, dynamic, static, read/write, read-only, random access, sequential access, location addressable, file addressable, and content addressable. In some embodiments, logic subsystem 402 and data-holding subsystem 404 may be integrated into one or more common devices, such as an application specific integrated circuit or a system on a chip.

FIG. 4 also shows an aspect of the data-holding subsystem in the form of removable computer-readable storage media 412, which may be used to store and/or transfer data and/or instructions executable to implement the herein described methods and processes. Removable computer-readable storage media 412 may take the form of CDs, DVDs, HD-DVDs, Blu-Ray Discs, EEPROMs, and/or floppy disks, among others.

It is to be appreciated that data-holding subsystem 404 includes one or more physical, non-transitory devices. In contrast, in some embodiments aspects of the instructions described herein may be propagated in a transitory fashion by a pure signal (e.g., an electromagnetic signal, an optical signal, etc.) that is not held by a physical device for at least a finite duration. Furthermore, data and/or other forms of information pertaining to the present disclosure may be propagated by a pure signal.

When included, display subsystem 406 may be used to present a visual representation of data held by data-holding subsystem 404. As the herein described methods and processes change the data held by the data-holding subsystem, and thus transform the state of the data-holding subsystem, the state of display subsystem 406 may likewise be transformed to visually represent changes in the underlying data. Display subsystem 406 may include one or more display devices utilizing virtually any type of technology. Such display devices may be combined with logic subsystem 402 and/or data-holding subsystem 404 in a shared enclosure, or such display devices may be peripheral display devices.

When included, communication subsystem 408 may be configured to communicatively couple computing system 400 with one or more other computing devices. Communication subsystem 408 may include wired and/or wireless communication devices compatible with one or more different communication protocols. As nonlimiting examples, the communication subsystem may be configured for communication via a wireless telephone network, a wireless local area network, a wired local area network, a wireless wide area network, a wired wide area network, etc. In some embodiments, the communication subsystem may allow computing system 400 to send and/or receive messages to and/or from other devices via a network such as the Internet.

In some embodiments, sensor subsystem 410 may include a depth camera 414. Depth camera 414 may include left and right cameras of a stereoscopic vision system, for example. Time-resolved images from both cameras may be registered to each other and combined to yield depth-resolved video.

In other embodiments, depth camera 414 may be a structured light depth camera configured to project a structured infrared illumination comprising numerous, discrete features (e.g., lines or dots). Depth camera 414 may be configured to image the structured illumination reflected from a scene onto which the structured illumination is projected. Based on the spacings between adjacent features in the various regions of the imaged scene, a depth map of the scene may be constructed.

In other embodiments, depth camera 414 may be a time-of-flight camera configured to project a pulsed infrared illumination onto the scene. The depth camera may include two cameras configured to detect the pulsed illumination reflected from the scene. Both cameras may include an electronic shutter synchronized to the pulsed illumination, but the integration times for the cameras may differ, such that a pixel-resolved time-of-flight of the pulsed illumination, from the source to the scene and then to the cameras, is discernable from the relative amounts of light received in corresponding pixels of the two cameras.

In some embodiments, sensor subsystem 410 may include an visible light camera 416. Virtually any type of digital camera technology may be used without departing from the scope of this disclosure. As a nonlimiting example, visible light camera 416 may include a CCD image sensor.

It is to be understood that the configurations and/or approaches described herein are exemplary in nature, and that these specific embodiments or examples are not to be considered in a limiting sense, because numerous variations are possible. The specific routines or methods described herein may represent one or more of any number of processing strategies. As such, various acts illustrated may be performed in the sequence illustrated, in other sequences, in parallel, or in some cases omitted. Likewise, the order of the above-described processes may be changed.

The subject matter of the present disclosure includes all novel and nonobvious combinations and subcombinations of the various processes, systems and configurations, and other features, functions, acts, and/or properties disclosed herein, as well as any and all equivalents thereof. 

The invention claimed is:
 1. A method of calculating a gain setting for a primary image sensor, the method comprising: receiving a test matrix of pixels from a test image sensor; receiving a first-frame matrix of pixels from the primary image sensor; and calculating a gain setting for the primary image sensor using the first-frame matrix of pixels except those pixels imaging one or more exclusion regions identified from the test matrix of pixels.
 2. The method of claim 1, where calculating a gain setting includes constructing a histogram of the first-frame matrix of pixels except the pixels imaging the one or more exclusion regions.
 3. The method of claim 1, further comprising applying the calculated gain setting to the primary sensor for subsequent matrices of pixels.
 4. The method of claim 1, where each pixel in the first-frame matrix includes visible light information indicating an intensity of visible light observed at that pixel.
 5. The method of claim 1, where each pixel in the test matrix includes infrared light information indicating an intensity of infrared light observed at that pixel.
 6. The method of claim 5, further comprising finding a depth of an object observed at each pixel, wherein the exclusion regions include a subset of pixels that image an object not within a threshold tolerance of a reference depth.
 7. The method of claim 5, further comprising finding a surface temperature of an object observed at each pixel, wherein the exclusion regions include a subset of pixels that image an object not within a threshold tolerance of a reference surface temperature.
 8. The method of claim 5, further comprising comparing a first matrix of pixels indicating an intensity of infrared light observed at a pixel while infrared light is being projected to that pixel and a second matrix of pixels indicating an intensity of infrared light observed at that pixel while infrared light is not being projected to that pixel, wherein the exclusion regions include that pixel if the intensity of infrared light observed at that pixel while infrared light is being projected to that pixel is within a threshold tolerance of the intensity of infrared light observed at that pixel while infrared light is not being projected to that pixel.
 9. A data-holding subsystem holding instructions executable by a logic subsystem to: receive a test matrix of pixels from a test image sensor; identify one or more exclusion regions imaged by a subset of the test matrix of pixels; receive a first-frame matrix of pixels from the primary image sensor; and calculate an exposure setting for the primary image sensor using the first-frame matrix of pixels except those pixels imaging the one or more exclusion regions.
 10. The data-holding subsystem of claim 9, where the exposure setting is a gain setting.
 11. The data-holding subsystem of claim 9, where calculating an exposure setting includes constructing a histogram of the first-frame matrix of pixels except the pixels imaging the one or more exclusion regions.
 12. The data-holding subsystem of claim 9, where the calculated exposure setting is applied to the primary sensor for subsequent matrices of pixels.
 13. The data-holding subsystem of claim 9, where each pixel in the first-frame matrix includes visible light information indicating an intensity of visible light observed at that pixel.
 14. The data-holding subsystem of claim 9, where each pixel in the test matrix includes infrared light information indicating an intensity of infrared light observed at that pixel.
 15. The data-holding subsystem of claim 14, further holding instructions executable by the logic subsystem to: find a depth of an object observed at each pixel, wherein the exclusion regions include a subset of pixels that image an object not within a threshold tolerance of a reference depth.
 16. The data-holding subsystem of claim 14, further holding instructions executable by the logic subsystem to: find a surface temperature of an object observed at each pixel, wherein the exclusion regions include a subset of pixels that image an object not within a threshold tolerance of a reference surface temperature.
 17. The data-holding subsystem of claim 14, further holding instructions executable by the logic subsystem to: compare a first matrix of pixels indicating an intensity of infrared light observed at a pixel while infrared light is being projected to that pixel and a second matrix of pixels indicating an intensity of infrared light observed at that pixel while infrared light is not being projected to that pixel, wherein the exclusion regions include that pixel if the intensity of infrared light observed at that pixel while infrared light is being projected to that pixel is within a threshold tolerance of the intensity of infrared light observed at that pixel while infrared light is not being projected to that pixel.
 18. A method of calculating a gain setting for a visible light image sensor, the method comprising: receiving a test matrix of pixels from an infrared image sensor; identifying one or more exclusion regions imaged by a subset of the test matrix of pixels; receiving a first-frame matrix of visible light pixels from the visible light image sensor; and calculating a gain setting for the visible light image sensor using the first-frame matrix of visible light pixels except those pixels imaging the one or more exclusion regions.
 19. The method of claim 18, further comprising applying the calculated gain setting to the primary sensor for subsequent matrices of pixels.
 20. The method of claim 18, where calculating a gain setting includes constructing a histogram of the first-frame matrix of pixels except the pixels imaging the one or more exclusion regions. 